package top.gangster.lunan.userservice.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import java.util.List;
import top.gangster.lunan.userservice.entity.Role;
import top.gangster.lunan.userservice.entity.User;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import top.gangster.lunan.userservice.entity.UserSave;

/**
 * <p>
 * 使用这个系统的用户表，包含用户的登录与基础信息 Mapper 接口
 * </p>
 *
 * @author vic
 * @since 2021-11-06
 */
public interface UserMapper extends BaseMapper<User> {

  IPage<UserSave> selectPageUserList(Page<?> page);
  IPage<UserSave> selectPageUserByName(Page<?> page,String username);
  IPage<UserSave> selectPageUserByPhone(Page<?> page,String phonenumber);
  IPage<UserSave> selectPageUserByDept(Page<?> page,String deptname);
  IPage<UserSave> selectPageUserByRole(Page<?> page,String role);
  List<UserSave> selectUserByRole(String roleId);
  List<UserSave> selectUserByDept(String deptId);
}
